#include <iostream>
#include <stdio.h>

class test
{
    public:
        int id;
        int score;
        test(int id = 1, int score = 2):id(id), score(score){}
        void update(void);
};

struct xxx
{
    int a;
    int b[0];
};

void test::update(void)
{
    int test::* ptr = & test::id;
    int * temp = & (this->score);
//    this->*(ptr) = 5;
    this->*ptr = 5;
//    *(ptr) = 5;
    *temp = 4;
}

int func(void)
{
    printf("func:%s line:%d\n", __func__, __LINE__);
    return 0;
}

int main(void)
{
    test t;
    test t2;
    printf("%d,%d\n", t.id, t.score);
//    t.update();
//    printf("%d,%d\n", t.id, t.score);
    int test::*ptr  = & test::id;
    printf("%d\n", ptr);
    printf("-------------%d\n", sizeof(struct xxx));

    func();

    return 0;
}

